← Index
NYTProf Performance Profile   
For flows_to_es.pl
  Run on Mon May 9 23:27:59 2016
Reported on Mon May 9 23:28:09 2016

Filename(eval 56)[/usr/share/perl5/Sub/Quote.pm:5]
StatementsExecuted 26 statements in 429µs
Eval Invoked At/usr/share/perl5/Sub/Quote.pm line 5
Sibling evals1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
22222µs1.03msSearch::Elasticsearch::Logger::LogAny::::newSearch::Elasticsearch::Logger::LogAny::new
11113µs24µsSub::Quote::::BEGIN@3.13 Sub::Quote::BEGIN@3.13
1117µs7µsMethod::Generate::Constructor::::BEGIN@6.14 Method::Generate::Constructor::BEGIN@6.14
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1{
222µs my $_QUOTED = ${$_[1]->{"\$_QUOTED"}};
3263µs235µs
# spent 24µs (13+11) within Sub::Quote::BEGIN@3.13 which was called: # once (13µs+11µs) by Sub::Quote::_clean_eval at line 3
no warnings 'closure';
# spent 24µs making 1 call to Sub::Quote::BEGIN@3.13 # spent 11µs making 1 call to warnings::unimport
4
# spent 1.03ms (22µs+1.01) within Search::Elasticsearch::Logger::LogAny::new which was called 2 times, avg 515µs/call: # once (6µs+1.01ms) by Search::Elasticsearch::new at line 40 of /opt/flows/lib/lib/perl5/Search/Elasticsearch.pm # once (16µs+0s) by Search::Elasticsearch::new at line 53 of Sub/Defer.pm
sub Search::Elasticsearch::Logger::LogAny::new {
5package Method::Generate::Constructor;
6
# spent 7µs within Method::Generate::Constructor::BEGIN@6.14 which was called: # once (7µs+0s) by Sub::Quote::_clean_eval at line 11
BEGIN {
711µs $^H = "2018";
81500ns ${^WARNING_BITS} = "\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\003";
916µs %^H = (
10 );
111332µs17µs}
# spent 7µs making 1 call to Method::Generate::Constructor::BEGIN@6.14
121500ns my $class = shift;
131200ns $class = ref($class) if ref($class);
141300ns if ($class ne "Search::Elasticsearch::Logger::LogAny") {
15 if ($Moo::MAKERS{$class}) {
16 Moo->_constructor_maker_for($class,"Search::Elasticsearch::Logger::LogAny");
17 return $class->new(@_);
18 } elsif ($INC{"Moose.pm"} and my $meta = Class::MOP::get_metaclass_by_name($class)) {
19 return $meta->new_object($class->BUILDARGS(@_));
20 }
21 }
221100ns my $args;
231800ns if ( scalar @_ == 1 ) {
241700ns unless ( defined $_[0] && ref $_[0] eq 'HASH' ) {
25 die "Single parameters to new() must be a HASH ref"
26 ." data => ". $_[0] ."\n";
27 }
2812µs $args = { %{ $_[0] } };
29 }
30 elsif ( @_ % 2 ) {
31 die "The new() method for $class expects a hash reference or a key/value list."
32 . " You passed an odd number of arguments\n";
33 }
34 else {
35 $args = {@_};
36 }
3712µs if (my @missing = grep !exists $args->{$_}, qw(serializer)) {
38 die "Missing required arguments: ".join(', ', sort @missing);
39 }
4011µs my $new = bless({}, $class);;
4114µs $new->{"log_as"} = (
42 exists $args->{"log_as"}
43 ? $args->{"log_as"}
44 : "elasticsearch.event"
45 );
461300ns if (exists $args->{"log_handle"}) {
47 $new->{"log_handle"} = $args->{"log_handle"};
48 }
491200ns if (exists $args->{"log_to"}) {
50 $new->{"log_to"} = $args->{"log_to"};
51 }
521700ns if (exists $args->{"serializer"}) {
53 $new->{"serializer"} = $args->{"serializer"};
54 }
551500ns $new->{"trace_as"} = (
56 exists $args->{"trace_as"}
57 ? $args->{"trace_as"}
58 : "elasticsearch.trace"
59 );
601300ns if (exists $args->{"trace_handle"}) {
61 $new->{"trace_handle"} = $args->{"trace_handle"};
62 }
631100ns if (exists $args->{"trace_to"}) {
64 $new->{"trace_to"} = $args->{"trace_to"};
65 }
6614µs return $new;
67 }
6811µs $_QUOTED->[3] = \&Search::Elasticsearch::Logger::LogAny::new
69}
7015µs1;
71
72;